package edu.hnu.tradeserver.config;

import feign.RequestInterceptor;
import feign.RequestTemplate;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Configuration;


@Configuration
public class FeignConfiguration implements RequestInterceptor {

    @Value("${allow.secret}")
    String allowSecret;

    @Override
    public void apply(RequestTemplate requestTemplate) {
        requestTemplate.header("allow",allowSecret);
    }
}
